#include "CSingaporeBusListBox.h"
#include "SingaporeBusStructures.h"

#ifndef SINGAPOREBUSDRAWITEMS_H_
#define SINGAPOREBUSDRAWITEMS_H_

struct CArrivalTimeItem;

class CSingaporeBusDrawItems
	{
private:
	mutable CFont* iPrimaryFont;
	mutable TRgb iSkinTextColor, iSkinHighlightTextColor;
	mutable TBool iValidSkinTextColor, iValidSkinHighlightTextColor;
	CSingaporeBusListBoxItemDrawer* iDrawer;
	TBool iItemIsCurrent;
	TTimeIntervalMicroSeconds iIntervalSincePreviousCurrentItemChange;

public:
	CSingaporeBusDrawItems();
	const CFont* PrimaryFont() const;
	const CFont* SecondaryFont() const;
	const TRgb& CSingaporeBusDrawItems::SkinTextColor() const;
	const TRgb& CSingaporeBusDrawItems::SkinHighlightTextColor() const;
	
	
	void BeginDrawItemL(
			CSingaporeBusListBoxItemDrawer* aDrawer,
			const TRect& aRect, 
			TBool aItemIsCurrent,
			TRect& aClientRect);
	void EndDrawItemL();
	void DrawTextL(
			const TRect& aRect, const CFont* aFont,
			const TDesC8& aText, CGraphicsContext::TTextAlign aAlign = CGraphicsContext::ELeft) const;
	void DrawTextL(
			const TRect& aRect, const CFont* aFont,
			const TDesC& aText, CGraphicsContext::TTextAlign aAlign = CGraphicsContext::ELeft) const;
	void DrawServiceNameL(
			const TRect& aRect, const CFont* aFont,
			const TService* aService) const;
	void DrawStationNumberL(
			const TRect& aRect, const CFont* aFont,
			const TStation* aStation) const;
	void DrawServiceDirectionL(
			const TRect& aRect, const CFont* aFont,
			const TService* aService) const;
	void DrawDistanceL(
			const TRect& aRect, const CFont* aFont,
			const TCoordinate& aCoord1, const TCoordinate& aCoord2) const;
	void DrawArrivalTimeL(
			const TRect& aRect, const CFont* aFont,
			const CArrivalTimeItem* aArrivalTime) const;
	void DrawIconL(
			const TRect& aRect,
			TInt aIconIndex) const;
	void DrawBackgroundL(
			const TRect& aRect) const;

	
	~CSingaporeBusDrawItems();

	};


#endif /* SINGAPOREBUSDRAWITEMS_H_ */
